<?php
$priceConfigTable = new BPSheet('orderPriceConfig');
$priceConfigView = array();
?>

<?php
$viewData = array();
if (isset($eventId)) {
    $viewData['eventId'] = $eventId;
}
if (isset($configId)) {
    $viewData['configId'] = $configId;
}
if (isset($orderPriceConfigId)) {
    $viewData['orderPriceConfigId'] = $orderPriceConfigId;
} else {
    $viewData['orderPriceConfigId'] = 0;
}
?>
<legend><h4>
        <?php echo $control->getAjaxLink(array('name' => '活动列表', 'id' => 'showEventList')); ?>\
        <?php echo $control->getAjaxLink(array('name' => '订单配置列表', 'id' => 'showOrderConfigList'), array('eventId' => $eventId)); ?>\
        <?php echo $control->getAjaxLink(array('name' => '添加订单配置', 'id' => 'showAddOrderConfig'), array('eventId' => $eventId, 'configId' => $configId)); ?>\
        <?php echo $control->getAjaxLink(array('name' => '订单价格配置列表', 'id' => 'showOrderPriceConfigList'), array('eventId' => $eventId, 'configId' => $configId)); ?>\
        <?php echo '添加订单价格配置'; ?>
    </h4>
</legend>
<div class="tabbable tabs-right" style="margin-top: 0px;"> <!-- Only required for left/right tabs -->
    <ul class="nav nav-tabs" style="margin-bottom: 15px">
        <li class="active"><a href="#tab1" data-toggle="tab"><?php echo '基本设置'; ?></a></li>    
        <li class=""><a href="#tab2" data-toggle="tab"><?php echo '产品价格设置'; ?></a></li>
        <li class=""><a href="#tab3" data-toggle="tab"><?php echo '买家价格设置'; ?></a></li>
        <li class=""><a href="#tab4" data-toggle="tab"><?php echo '卖家价格设置'; ?></a></li>
        <li class=""><a href="#tab5" data-toggle="tab"><?php echo '时间段价格设置'; ?></a></li>
    </ul>
    <div class="tab-content">
        <div class="tab-pane active" id="tab1" style="min-height: 270px">                
            <?php
            $control->renderView('orderConfig_add_priceConfig_info', $viewData);
            ?>  
        </div>  
        <div class="tab-pane" id="tab2" style="min-height: 270px">                
            <?php
            $control1 = new BUIControl('showPriceConfigForProduct');
            $control1->addRenderView('showPriceConfigForProduct', 'orderConfig_add_priceConfig_product', $viewData);
            $control1->render();
            ?>  
        </div>
        <div class="tab-pane" id="tab3" style="min-height: 270px">                
            <?php
            //$control->renderView('priceConfig_add_product_list', $viewData);
            //$viewData['pageControl'] = $control;
            $control2 = new BUIControl('showPriceConfigForBuyer');
            $control2->addRenderView('showPriceConfigForBuyer', 'orderConfig_add_priceConfig_buyer', $viewData);
            $control2->render();
            ?>  
        </div>
        <div class="tab-pane" id="tab4" style="min-height: 270px">                
            <?php
            $control3 = new BUIControl('showPriceConfigForVender');
            $control3->addRenderView('showPriceConfigForVender', 'orderConfig_add_priceConfig_vender', $viewData);
            $control3->render();
            ?>  
        </div>
        <div class="tab-pane" id="tab5" style="min-height: 270px">                
            <?php
            $control4 = new BUIControl('showPriceConfigForTimeSlot');
            $control4->addRenderView('showPriceConfigForTimeSlot', 'orderConfig_add_priceConfig_timeslot_list', $viewData);
            $control4->render();
            ?>  
        </div>
    </div>
</div>
